import request from '@/utils/request'

// 查询质量通报列表
export function listPhysicalReport(query) {
  return request({
    url: '/quality/physicalReport/list',
    method: 'get',
    params: query
  })
}

// 查询质量通报详细
export function getPhysicalReport(reportId) {
  return request({
    url: '/quality/physicalReport/' + reportId,
    method: 'get'
  })
}

// 新增质量通报
export function addPhysicalReport(data) {
  return request({
    url: '/quality/physicalReport',
    method: 'post',
    data: data
  })
}

// 修改质量通报
export function updatePhysicalReport(data) {
  return request({
    url: '/quality/physicalReport',
    method: 'put',
    data: data
  })
}

// 删除质量通报
export function delPhysicalReport(reportId) {
  return request({
    url: '/quality/physicalReport/' + reportId,
    method: 'delete'
  })
}

// 查询质量通报最大通报数
export function getMaxNumber(query) {
  return request({
    url: '/quality/physicalReport/getMaxNumber',
    method: 'get',
    params: query
  })
}
